package com.javaweb.task;

import com.javaweb.base.BaseInject;

//使用请解注
//@Component
//@Async//若该类所有方法都是异步执行方法，则直接在该类上加上@Async即可，类里的方法就不需要都加上@Async了
public class UnUsedScheduledTask3 extends BaseInject {
    
    /**
    @Async  
    //public Future<String> task3() throws InterruptedException {
    public void task3() throws InterruptedException {  
        long currentTimeMillis1 = System.currentTimeMillis();  
        Thread.sleep(3000);  
        long currentTimeMillis2 = System.currentTimeMillis();  
        System.out.println("task3任务耗时:"+(currentTimeMillis2-currentTimeMillis1)+"ms");  
        //return new AsyncResult<String>("task3执行完毕");  
    }
    */
	
}
